﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace 游戏平台原型
{
    public partial class roomwindow : UserControl
    {
        public roomwindow()
        {
            InitializeComponent();
        }

        private void btn_room_panel1_Click(object sender, EventArgs e)
        {
            if (btn_room_panel1.Text== "添加画板")
            {
                Form_AddPanel form = new Form_AddPanel(1, new ChangePanelStateHandler(changepanelstate));
                form.ShowDialog();
            }
            else{

            }

        }
        private void changepanelstate(int id, string state)
        {
            switch (id)
            {
                case 0:
                    btn_room_panel1.Text = state; break;
                case 1:
                    btn_room_panel1.Text = state; break;
                case 2:
                    btn_room_panel1.Text = state; break;
                case 3:
                    btn_room_panel1.Text = state; break;
                case 4:
                    btn_room_panel1.Text = state; break;
                case 5:
                    btn_room_panel1.Text = state; break;
            }
        }

        private void btn_room_panel2_Click(object sender, EventArgs e)
        {

        }

        private void 删除ToolStripMenuItem_Click(object sender, EventArgs e)
        {

        }
    }
}
